package unipampa.extensions.games.pampaPife;

import com.smartfoxserver.v2.core.ISFSEvent;
import com.smartfoxserver.v2.entities.User;
import com.smartfoxserver.v2.exceptions.SFSException;
import com.smartfoxserver.v2.extensions.BaseServerEventHandler;
import com.smartfoxserver.v2.core.SFSEventParam;

public class TratarDesconecta extends BaseServerEventHandler{

	@SuppressWarnings("null")
	public void handleServerEvent(ISFSEvent event) throws SFSException {
		PampaPifeExtension gameExt = (PampaPifeExtension) getParentExtension();
		SFSEventParam evtParam = null;
		User player = (User) event.getParameter(evtParam.USER);
		gameExt.baralho.devolveCartas(player.getPlayerId());
		trace("Devolvendo cartas do jogador "+player.getPlayerId());
	}
}
